<template>
  <base-dialog v-bind="$attrs" v-on="$listeners" title="修改审批意见" :close-on-click-modal="false" append-to-body size="tiny"  @submit="toAdd">
    <el-form ref="elForm" :model="formData" :rules="rules" size="medium">
      <!--        <el-form-item label="授权码" prop="code" v-if="showCode">-->
      <!--          <el-input v-model="formData.code" placeholder="请输入授权码" :maxlength="6" clearable style="width: calc(100% - 122px)">-->
      <!--          </el-input>-->
      <!--          <el-button plain type="primary" style="margin-left: 10px" @click="sendMsg">获取授权码</el-button>-->
      <!--        </el-form-item>-->
      <el-form-item label="审批意见" prop="suggestion">
        <el-input v-model="formData.suggestion" type="textarea" placeholder="请输入审批意见"
                  :autosize="{minRows: 4, maxRows: 4}" :style="{width: '100%'}"></el-input>
      </el-form-item>
    </el-form>
  </base-dialog>
</template>
<script>
  import messageModify from "@/api/systemManagement/workOrder/messageModify/index";
  import BaseDialog from '@/components/Common/BaseDialog'
  import DetailDialog from '@/mixins/DetailDialog'
  export default {
    name:"EditDialog",
    inheritAttrs: false,
    components: { BaseDialog },
    mixins: [DetailDialog],
    data() {
      return {
        apiUrl:"systemManagement/workOrder/messageModify",
        formData: {
          code: '',
          suggestion: undefined,
        },
        rules: {
          code: [{
            required: true,
            message: '请输入授权码',
            trigger: 'blur'
          }, {
            pattern: /^[a-z0-9]{4,6}$/,
            message: '请输入正确的验证码',
            trigger: 'blur'
          }],
          suggestion: [],
        },
      }
    },
    computed: {},
    watch: {},
    created() {
    },
    mounted() {},
  }
</script>
<style>
</style>
